<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>5. Generating Sitemaps &mdash; Documentation</title>
    <link rel="stylesheet" href="_static/sphinxdoc.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '',
        VERSION:     '',
        COLLAPSE_MODINDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="top" title="Documentation" href="index.html" />
    <link rel="next" title="Glossary" href="glossary.html" />
    <link rel="prev" title="Page Structure and Navigation" href="navigation.html" /> 
  </head>
  <body>
    <div style="background-color: #FFF; text-align: left; padding: 8px 0px"><img src="_static/banner300910.gif"></div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="modindex.html" title="Global Module Index"
             accesskey="M">modules</a> |</li>
        <li class="right" >
          <a href="glossary.html" title="Glossary"
             accesskey="N">next</a> |</li>
        <li class="right" >
          <a href="navigation.html" title="Page Structure and Navigation"
             accesskey="P">previous</a> |</li>
        <li><a href="index.html">Documentation</a> &raquo;</li> 
      </ul>
    </div>
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
            <h3><a href="index.html">Table Of Contents</a></h3>
            <ul>
<li><a class="reference external" href="">5. Generating Sitemaps</a><ul>
<li><a class="reference external" href="#example">Example</a></li>
</ul>
</li>
</ul>

            <h4>Previous topic</h4>
            <p class="topless"><a href="navigation.html"
                                  title="previous chapter">Page Structure and Navigation</a></p>
            <h4>Next topic</h4>
            <p class="topless"><a href="glossary.html"
                                  title="next chapter">Glossary</a></p>
            <h3>This Page</h3>
            <ul class="this-page-menu">
              <li><a href="_sources/sitemap.txt"
                     rel="nofollow">Show Source</a></li>
            </ul>
          <div id="searchbox" style="display: none">
            <h3>Quick search</h3>
              <form class="search" action="search.html" method="get">
                <input type="text" name="q" size="18" />
                <input type="submit" value="Go" />
                <input type="hidden" name="check_keywords" value="yes" />
                <input type="hidden" name="area" value="default" />
              </form>
              <p class="searchtip" style="font-size: 90%">
              Enter search terms or a module, class or function name.
              </p>
          </div>
          <script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="module-sitemap">
<h1>5. Generating Sitemaps<a class="headerlink" href="#module-sitemap" title="Permalink to this headline">¶</a></h1>
<p>The <cite>sitemap</cite> module can be to generate sitemap.xml for search engines to index the site
as per <a class="reference external" href="http://www.sitemaps.org/protocol.php">http://www.sitemaps.org/protocol.php</a></p>
<p>The sitemap module will generate urls for</p>
<ul class="simple">
<li>All pages with Guest access in Page Role</li>
<li>Upto 1000 Records for upto 10 <cite>DocTypes</cite> with read permission for Guest at level 0, ordered by last modified date
(most recent)</li>
</ul>
<dl class="function">
<dt id="sitemap.create">
<tt class="descclassname">sitemap.</tt><tt class="descname">create</tt><big>(</big><em>site_prefix</em>, <em>fname = Name</em><big>)</big><a class="headerlink" href="#sitemap.create" title="Permalink to this definition">¶</a></dt>
<dd>Creates a sitemap.xml file and places in the same folder as the <cite>index.cgi</cite> file</dd></dl>

<div class="section" id="example">
<h2>Example<a class="headerlink" href="#example" title="Permalink to this headline">¶</a></h2>
<p>The sitemap can be generated by <cite>cron</cite> or manually. Pass the full site address including &#8220;<a class="reference external" href="http://">http://</a>&#8220;:</p>
<div class="highlight-python"><pre>python path-to-v170/cgi-bin/webnotes/utils/sitemap.py http://www.example.com/</pre>
</div>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             >index</a></li>
        <li class="right" >
          <a href="modindex.html" title="Global Module Index"
             >modules</a> |</li>
        <li class="right" >
          <a href="glossary.html" title="Glossary"
             >next</a> |</li>
        <li class="right" >
          <a href="navigation.html" title="Page Structure and Navigation"
             >previous</a> |</li>
        <li><a href="index.html">Documentation</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
      &copy; Copyright 2010, Rushabh Mehta.
      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.3.
    </div>
  </body>
</html>